//
//  UIImage+MZCategory.m
//  MZToolkitDemo
//
//  Created by 沈家林 on 2018/6/11.
//  Copyright © 2018年 Chris Yang. All rights reserved.
//

#import "UIImage+MZCategory.h"

@implementation UIImage (MZCategory)

- (UIImage *)mzChangeWithSize:(CGSize)size{
    UIGraphicsBeginImageContextWithOptions(size, NO, 0.0);
    CGRect rect = CGRectMake(0, 0, size.width, size.height);
    [self drawInRect:rect];
    UIImage *image = UIGraphicsGetImageFromCurrentImageContext();
    UIGraphicsEndImageContext();
    return image;
}

@end
